//
//  SelectVideoClipView.h
//  OntheRoadV4
//
//  Created by ZhangYanhua on 15/3/4.
//  Copyright (c) 2015年 EricHuang. All rights reserved.
//

#import <UIKit/UIKit.h>

@class SelectVideoClipView;

@protocol SelectVideoClipViewDelegate <NSObject>

- (void)clipViewTouchedDidBegin:(SelectVideoClipView *)view;
- (void)clipViewTouchedDidMove:(SelectVideoClipView *)view;
- (void)clipViewTouchedDidEnd:(SelectVideoClipView *)view;

@end

@interface SelectVideoClipView : UIView

@property (nonatomic, weak) id<SelectVideoClipViewDelegate> delegate;

// 需要设置的属性
@property (nonatomic, assign) CGFloat leftRightMargin;
@property (nonatomic, assign) CGFloat maxWidth;
@property (nonatomic, assign) CGFloat minWidth;

// 可以查询的属性
@property (nonatomic, assign) CGFloat currentStartX;
@property (nonatomic, assign) CGFloat currentEndX;

@property (nonatomic, assign) BOOL touchedOnLeftView;
@property (nonatomic, assign) BOOL touchedOnRightView;

- (void)updateViewWithMinWidth:(CGFloat)minWidth maxWidth:(CGFloat)maxWidth margin:(CGFloat)margin;

- (void)updatePlayProgress:(CGFloat)progress;

- (void)showPlayPorgressWithAnimation:(BOOL)animated;
- (void)hidePlayProgressWithAnimation:(BOOL)animated;

@end
